define([
    "app"
], function (app) {
    app.config([
        "$stateProvider", "$urlRouterProvider",
        function ($stateProvider, $urlRouterProvider) {
            var baseUrl = pageTemplateUrl;

            // 设置默认的url，当出现意外的url跳转时，会返回到/main
            $urlRouterProvider.otherwise("/main");

            $stateProvider
                .state("main",{
                   url:"/main",
                   templateUrl:baseUrl + "main.html",
                    controller:"mainController"
                });
        }
    ]);
});